<?php
namespace Ana\AgendaBundle\Entity;

use Doctrine\ORM\Mapping as ORM;


/**
 * @ORM\Entity(repositoryClass="Ana\AgendaBundle\Entity\JornadaRepository")
 * @ORM\Table(name="jornada")
 * @ORM\HasLifecycleCallbacks()
 */

class Jornada{
    
    /**
    * @ORM\Column(type="integer")
    * @ORM\Id
    * @ORM\GeneratedValue(strategy="AUTO")
    */
    public $id;
    
    /**
    * @ORM\Column(type="date")
    */
    public $fecha;
    
    /**
    * @ORM\OneToMany(targetEntity="Turno", mappedBy="jornada")
    **/
    public $turnos;
    
    /**
    * @ORM\Column(type="smallint")
    */
    public $cant_turnos;
    
    /**
    * @ORM\Column(type="boolean")
    */
    public $completo;
    /**
     * Constructor
     */
    public function __construct()
    {
        $this->turnos = new \Doctrine\Common\Collections\ArrayCollection();
    }

    /**
     * Get id
     *
     * @return integer 
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set fecha
     *
     * @param \DateTime $fecha
     * @return Jornada
     */
    public function setFecha($fecha)
    {
        $this->fecha = $fecha;

        return $this;
    }

    /**
     * Get fecha
     *
     * @return \DateTime 
     */
    public function getFecha()
    {
        return $this->fecha;
    }

    /**
     * Set cant_turnos
     *
     * @param integer $cantTurnos
     * @return Jornada
     */
    public function setCantTurnos($cantTurnos)
    {
        $this->cant_turnos = $cantTurnos;

        return $this;
    }

    /**
     * Get cant_turnos
     *
     * @return integer 
     */
    public function getCantTurnos()
    {
        return $this->cant_turnos;
    }

    /**
     * Set completo
     *
     * @param boolean $completo
     * @return Jornada
     */
    public function setCompleto($completo)
    {
        $this->completo = $completo;

        return $this;
    }

    /**
     * Get completo
     *
     * @return boolean 
     */
    public function getCompleto()
    {
        return $this->completo;
    }

    /**
     * Add turnos
     *
     * @param \Ana\AgendaBundle\Entity\Turno $turnos
     * @return Jornada
     */
    public function addTurno(\Ana\AgendaBundle\Entity\Turno $turnos)
    {
        $this->turnos[] = $turnos;

        return $this;
    }

    /**
     * Remove turnos
     *
     * @param \Ana\AgendaBundle\Entity\Turno $turnos
     */
    public function removeTurno(\Ana\AgendaBundle\Entity\Turno $turnos)
    {
        $this->turnos->removeElement($turnos);
    }

    /**
     * Get turnos
     *
     * @return \Doctrine\Common\Collections\Collection 
     */
    public function getTurnos()
    {
        return $this->turnos;
    }
}
